<template>
  <van-config-provider class="root-node" :theme="commonStore.theme">
    <router-view v-slot="{ Component }">
      <transition name="router-fade" mode="out-in">
        <component :is="Component" />
      </transition>
    </router-view>
  </van-config-provider>
</template>

<script setup>
  import { useCommonStore } from '@/store/common'

  dayjs.locale('zh-cn')

  const commonStore = useCommonStore()
</script>

<style lang="less">
  body,
  #app,
  .root-node {
    color: var(--van-text-color);
  }
  .root-node {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: var(--van-background);
  }
</style>
